<!DOCTYPE html>
<html lang='en'>
<head>
 <meta charset='UTF-8'>
 <meta http-equiv='X-UA-Compatible' content='IE=edge'>
 <meta name='viewport' content='width=device-width, initial-scale=1.0'>
 <title>Document</title>
 <script src='../public/js/vue.js'></script>
</head>
<body>
  <div id='app'>
    <!-- 遍历对象 -->
    <ul>
      <li v-for="item in user">{{item}}</li>
    </ul>
    <!-- 
      遍历对象，获取key 和 value 
      格式: (value, key)
    -->
    <ul>
      <li v-for="(value, key) in user">{{value + key}}</li>
    </ul>
    <!-- 
      遍历对象，获取key 和 value 、index
      格式: (value, key, index)
      一遍不会获取 index
    -->
    <ul>
      <li v-for="(value, key, index) in user">{{value + key + index}}</li>
    </ul>
  </div>
  <script>
  const app = new Vue({
    el: '#app',
    data() {
      return {
        user: {
          name: 'yoyo',
          age:'1',
          height:'172'
        }
      }
    },
    methods:{
 
    },
    computed:{
 
    }
  })
  </script>
</body>
</html>